/**
 *  咨询统计
 */

import { baseUrl, doRequestPost, doRequestDel, doRequestPut, doRequestGet ,downloadRequest} from '@/utils/request'

// 按账户统计
export function getAcountlist(query) {
    return doRequestPost(baseUrl + 'news/statistics/pageListByAccount' + '?time=' + (+new Date()), query)
}

// 按平台统计
export function getPlatformlist(query) {
    return doRequestPost(baseUrl + 'news/statistics/pageListByPlatform' + '?time=' + (+new Date()), query)
}
// 按来源统计
export function getSourcelist(query) {
    return doRequestPost(baseUrl + 'news/statistics/pageListBySource' + '?time=' + (+new Date()), query)
}


//图表
export function getPlatformChartlist(query) {
    return doRequestPost(baseUrl + 'news/statistics/lineGraphByPlatform' + '?time=' + (+new Date()), query)
}

// 导出 excel 账户
export function exportExcel_account(query) {
    return downloadRequest(baseUrl + 'news/statistics/exportListByAccount' + '?time=' + (+new Date()), 'post',query)
}


// 导出 excel  平台
export function exportExcel_platform(query) {
    return downloadRequest(baseUrl + 'news/statistics/exportListByPlatform' + '?time=' + (+new Date()), 'post',query)
}

// 导出 excel  来源
export function exportExcel_source(query) {
    return downloadRequest(baseUrl + 'news/statistics/exportListBySource' + '?time=' + (+new Date()), 'post',query)
}
